import java.awt.Image;
import javax.swing.Icon;
import javax.swing.ImageIcon;


public class IconResizer {
	ImageIcon icon;
	
	public IconResizer(ImageIcon image){
		icon = image;
	}
	
	public Icon getImage(){
		return icon;
	}
	
	public void setImage(ImageIcon image){
		icon = image;
	}
	
	public void resize (int height, int width){
		Image img = icon.getImage();
	    icon = new ImageIcon(img.getScaledInstance(width, height,java.awt.Image.SCALE_SMOOTH));
	}
}
